//
//  NSProgressMg.m
//  NSProgress
//
//  Created by 韩艳锋 on 2021/11/15.
//

#import "NSProgressMg.h"
#import "NSProgressMgImplicitly.h"
#import "NSProgressMgExplicitly.h"

@implementation NSProgressMg
+ (instancetype)explicitly:(BOOL)explicitly
{
    if (explicitly) {
        return [[NSProgressMgExplicitly alloc] init];
    } else {
        return [[NSProgressMgImplicitly alloc] init];
    }
}

- (instancetype)init {
    self = [super init];
    if (self) {
        _totalProgress1 = 100;
        _totalProgress2 = 100;
        _totalProgress3 = 100;
        _pendingUnitCount1 = 70;
    }
    return self;
}
- (void)reset {
    self.progress1.totalUnitCount = _totalProgress1;
    self.progress2.totalUnitCount = _totalProgress2;
    self.progress3.totalUnitCount = _totalProgress3;
    
    self.progress1.completedUnitCount = 0;
    self.progress2.completedUnitCount = 0;
    self.progress3.completedUnitCount = 0;
}
@end
